home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 8 / 008.d81 / slot machine (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  3KB  |  105 lines

  1. 10 poke53280,2:poke53281,0:print"[155]":z=0
  2. 20 goto720
  3. 30 print"[147]"
  4. 40 print"";
  5. 50 print"[169]               [223]"
  6. 60 print"       [146][154]bandito[155]     "
  7. 70 print"  [175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][155]"
  8. 80 print"                   "
  9. 90 print"    [146]     [146]     [146]     "
  10. 100 print"    [146]     [146]     [146]     "
  11. 110 print"    [146]     [146]     [146]     "
  12. 120 print"                   "
  13. 130 print"  [183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][155]"
  14. 140 print"       [146]            "
  15. 150 print"                   "
  16. 160 print"                   "
  17. 170 print"[145][145][145][185][185][181][157][145][181][157][145][181][157][145][181][157][145][181][157][145][185][185][155]"
  18. 180 print"";
  19. 190 print:print"[158]spent"tab(17)"won"tab(26)"balance"
  20. 200 print:print"                                     "
  21. 210 fori=1to700:nexti:ifz=0thengosub920:z=1
  22. 220 a=ti/60
  23. 230 x=int(rnd(ti)*5+1)
  24. 240 on x goto 290,260,270,250,280
  25. 250 a$="[193]":goto300
  26. 260 a$="[211]":goto300
  27. 270 a$="[218]":goto300
  28. 280 a$="[154][216]":goto300
  29. 290 a$="[158][209]"
  30. 300 print"";a$
  31. 310 y=int(rnd(ti)*5+1)
  32. 320 on y goto 360,350,340,370,330
  33. 330 b$="[193]":goto380
  34. 340 b$="[211]":goto380
  35. 350 b$="[218]":goto380
  36. 360 b$="[154][216]":goto380
  37. 370 b$="[158][209]"
  38. 380 print"";b$
  39. 390 z=int(rnd(ti)*5+1)
  40. 400 on z goto 410,450,420,440,430
  41. 410 c$="[193]":goto460
  42. 420 c$="[211]":goto460
  43. 430 c$="[218]":goto460
  44. 440 c$="[154][216]":goto460
  45. 450 c$="[158][209]"
  46. 460 print"";c$
  47. 470 b=ti/60:c=b-a
  48. 480 ifc<2then230
  49. 490 ifc<4then310
  50. 500 ifc<6then390
  51. 510 ifa$=b$andb$=c$thengoto530
  52. 520 goto610
  53. 530 print"jackpot[146]"
  54. 540 forx=1to10
  55. 550 fori=1to200:next
  56. 560 print"[145]       "
  57. 570 fori=1to200:next
  58. 580 print"[145]jackpot[146]"
  59. 590 nextx
  60. 600 s=s+.5:w=w+s:b1=w-s:goto640
  61. 610 ifa$=b$orb$=c$ora$=c$thenprint"[153]doubles[146]":goto630
  62. 620 print"[154] sorry ":s=s+.5:w=w:b1=w-s:goto640
  63. 630 s=s+.5:w=w+1:b1=w-s
  64. 640 print"[158]spent"tab(17)"won"tab(26)"balance"
  65. 650 fori=1to550:next
  66. 660 print"[153]";
  67. 670 printtab(6)"$"s tab(16)"$"w tab(28)"[150]$"b1:print"[155]"
  68. 680 gety$
  69. 690 ify$="[133]"thengosub920:goto40
  70. 700 ify$="[134]"thenprint"[145][145][145][145][145][145][156] final standing [146][154]":goto63000
  71. 710 goto680
  72. 720 print"[147]":print"   this program is a slot-machine":print
  73. 730 print"simulation. the one-armed bandit":print
  74. 740 print"accepts only half-dollars. you will":print
  75. 750 print"be asked to insert your coin by":print
  76. 760 print"typing f1. simply type f1":print
  77. 770 print"after each turn to continue the":print
  78. 780 print"the game. the computer will keep a":print
  79. 790 print"record of your losses and winnings.":print
  80. 800 print"if doubles appear you win":print
  81. 810 print"$1.00. if a jackpot appears you win":print
  82. 820 print"the amount you have spent. please":print
  83. 830 print"type c to continue directions."
  84. 840 getq$:ifq$<>"c"then840
  85. 850 print"[147]":print"   the program runs continously":print
  86. 860 print"upon the insertion of your coin.":print
  87. 870 print"therefore,to end the game just":print
  88. 880 print"press the f3 key. please insert":print
  89. 890 print"your coin to begin."
  90. 900 gety$:ify$<>"[133]"then900
  91. 910 goto30
  92. 920 fori=0to160step40
  93. 930 poke1245+i,121:poke1246+i,121:poke55517+i,0:poke55518+i,0
  94. 940 poke1285+i,121:poke1286+i,121:poke55557+i,1:poke55558+i,1
  95. 950 nexti
  96. 960 fori=160to0step-40
  97. 970 poke1245+i,121:poke1246+i,121:poke55517+i,1:poke55518+i,1
  98. 980 poke1285+i,121:poke1286+i,121:poke55557+i,0:poke55558+i,0
  99. 990 poke1285+i,117:poke55557+i,1
  100. 1000 nexti: return
  101. 63000 rem    connect back to l.s.
  102. 63001 fordl=1to2000:nextdl
  103. 63002 print"[147]load"chr$(34)"payload"chr$(34)",8":print"run"
  104. 63004 poke198,0:poke631,13:poke632,13:poke198,2:end
  105.